package com.google.code.jerseyclients;

/*
 * Olivier Lamy
 * Licensed to the Apache Software Foundation (ASF) under one
 * or more contributor license agreements.  See the NOTICE file
 * distributed with this work for additional information
 * regarding copyright ownership.  The ASF licenses this file
 * to you under the Apache License, Version 2.0 (the
 * "License"); you may not use this file except in compliance
 * with the License.  You may obtain a copy of the License at
 *
 *   http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing,
 * software distributed under the License is distributed on an
 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
 * KIND, either express or implied.  See the License for the
 * specific language governing permissions and limitations
 * under the License.
 */

import java.util.Map;

import com.google.code.jerseyclients.model.ProxyInformation;

/**
 * @author <a href="mailto:olamy@apache.org">Olivier Lamy</a>
 * @since 1.0
 * @version $Id: JerseyHttpClientConfig.java 8 2010-11-04 17:33:00Z oliver.lamy@gmail.com $
 */
public interface JerseyHttpClientConfig
{
    int getConnectionTimeOut();

    JerseyHttpClientConfig setConnectionTimeOut( int connectionTimeOut );

    int getReadTimeOut();

    JerseyHttpClientConfig setReadTimeOut( int readTimeOut );

    int getMaxConnections();

    JerseyHttpClientConfig setMaxConnections( int maxConnections );

    int getMaxConnectionsPerHost();

    JerseyHttpClientConfig setMaxConnectionsPerHost( int maxConnectionsPerHost );

    boolean isConnectionStaleCheckingEnabled();

    JerseyHttpClientConfig setConnectionStaleCheckingEnabled( boolean connectionStaleCheckingEnabled );

    int getConnectionPoolTimeOut();

    JerseyHttpClientConfig setConnectionPoolTimeOut( int connectionPoolTimeOut );

    JerseyHttpClientConfig setApplicationCode( String applicationCode );

    String getApplicationCode();

    JerseyHttpClientConfig setApplicationCodeHeader( String applicationCodeHeader );

    String getApplicationCodeHeader();

    JerseyHttpClientConfig setOptionnalHeaders( Map<String, String> optionnalHeaders );

    Map<String, String> getOptionnalHeaders();

    ProxyInformation getProxyInformation();

    JerseyHttpClientConfig setProxyInformation( ProxyInformation proxyInformation );

    boolean isReuseConnection();

    JerseyHttpClientConfig setReuseConnection( boolean reuseConnection );

    int getIdleConnectionTimeout();

    JerseyHttpClientConfig setIdleConnectionTimeout( int idleConnectionTimeout );
}
